package org.ejc.persist.model;

import java.io.Serializable;
import org.apache.commons.lang.builder.EqualsBuilder;
import org.apache.commons.lang.builder.HashCodeBuilder;
import org.apache.commons.lang.builder.ToStringBuilder;


/** @author Hibernate CodeGenerator */
public class ConventionRegistrantHasAdditionalInfoTypeDesc implements Serializable {

    /** identifier field */
    private org.ejc.persist.model.ConventionRegistrantHasAdditionalInfoTypeDescPK comp_id;

    /** nullable persistent field */
    private Integer additionalInfoText;

    /** nullable persistent field */
    private org.ejc.persist.model.AdditionalInfoTypeDesc additionalInfoTypeDesc;

    /** nullable persistent field */
    private org.ejc.persist.model.ConventionRegistrant conventionRegistrant;

    /** full constructor */
    public ConventionRegistrantHasAdditionalInfoTypeDesc(org.ejc.persist.model.ConventionRegistrantHasAdditionalInfoTypeDescPK comp_id, Integer additionalInfoText, org.ejc.persist.model.AdditionalInfoTypeDesc additionalInfoTypeDesc, org.ejc.persist.model.ConventionRegistrant conventionRegistrant) {
        this.comp_id = comp_id;
        this.additionalInfoText = additionalInfoText;
        this.additionalInfoTypeDesc = additionalInfoTypeDesc;
        this.conventionRegistrant = conventionRegistrant;
    }

    /** default constructor */
    public ConventionRegistrantHasAdditionalInfoTypeDesc() {
    }

    /** minimal constructor */
    public ConventionRegistrantHasAdditionalInfoTypeDesc(org.ejc.persist.model.ConventionRegistrantHasAdditionalInfoTypeDescPK comp_id) {
        this.comp_id = comp_id;
    }

    public org.ejc.persist.model.ConventionRegistrantHasAdditionalInfoTypeDescPK getComp_id() {
        return this.comp_id;
    }

    public void setComp_id(org.ejc.persist.model.ConventionRegistrantHasAdditionalInfoTypeDescPK comp_id) {
        this.comp_id = comp_id;
    }

    public Integer getAdditionalInfoText() {
        return this.additionalInfoText;
    }

    public void setAdditionalInfoText(Integer additionalInfoText) {
        this.additionalInfoText = additionalInfoText;
    }

    public org.ejc.persist.model.AdditionalInfoTypeDesc getAdditionalInfoTypeDesc() {
        return this.additionalInfoTypeDesc;
    }

    public void setAdditionalInfoTypeDesc(org.ejc.persist.model.AdditionalInfoTypeDesc additionalInfoTypeDesc) {
        this.additionalInfoTypeDesc = additionalInfoTypeDesc;
    }

    public org.ejc.persist.model.ConventionRegistrant getConventionRegistrant() {
        return this.conventionRegistrant;
    }

    public void setConventionRegistrant(org.ejc.persist.model.ConventionRegistrant conventionRegistrant) {
        this.conventionRegistrant = conventionRegistrant;
    }

    public String toString() {
        return new ToStringBuilder(this)
            .append("comp_id", getComp_id())
            .toString();
    }

    public boolean equals(Object other) {
        if ( (this == other ) ) return true;
        if ( !(other instanceof ConventionRegistrantHasAdditionalInfoTypeDesc) ) return false;
        ConventionRegistrantHasAdditionalInfoTypeDesc castOther = (ConventionRegistrantHasAdditionalInfoTypeDesc) other;
        return new EqualsBuilder()
            .append(this.getComp_id(), castOther.getComp_id())
            .isEquals();
    }

    public int hashCode() {
        return new HashCodeBuilder()
            .append(getComp_id())
            .toHashCode();
    }

}
